package com.liull.netty.zerocopy;

import java.io.IOException;
import java.net.ServerSocket;

import io.netty.util.NettyRuntime;
import io.netty.util.internal.SystemPropertyUtil;

/**
 * @Author: liull
 * @Description:
 * @Date: Created in 12:40 2020/10/24
 * @Modified By:
 */
public class OldServer {
    public static void main(String[] args) throws IOException {
        ServerSocket serverSocket = new ServerSocket(8899);
        int max = Math.max(1, SystemPropertyUtil.getInt(
                "io.netty.eventLoopThreads", NettyRuntime.availableProcessors() * 2));
        System.out.println(max);
        // while (true) {
        // Socket socket = serverSocket.accept();
        // DataInputStream dataInputStream = new DataInputStream(socket.getInputStream());
        // }

    }
}
